package com.atbun.eduservice.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@Component
@FeignClient(name = "service-order",fallback = OrderClientImpl.class)
public interface OrderClient {
//    远程调用order服务，根据用户id与课程id查询该课程是否被购买
    @GetMapping("/orderservice/order/isBuyCourse/{memberid}/{courseid}")
    public boolean isBuyCourse(@PathVariable String memberid, @PathVariable String courseid);
}
